# lib构建
FROM zhu-ying-docker.pkg.coding.net/kszy/public/python:3.11-slim 
# 设置用户为root
USER root
# python 编码
ENV PYTHONIOENCODING=utf-8
# pip配置
RUN pip config set global.index-url https://pypi-1703563938750:504b6dbe8de1f29495ad7efc6012a42a08e9cb2b@zhu-ying-pypi.pkg.coding.net/kszy/pypi/simple
# 安装依赖
RUN pip install pydantic==2.* polars==0.* matplotlib==3.* pyarmor==8.*
# 安装当前项目
ADD clinpatho/ /data/clinpatho/

RUN cd /data && pyarmor gen -i -r -O dist clinpatho
ADD setup.py setup.cfg /data/dist/
RUN cd /data/dist && pip install . 
RUN rm -rf /data
